package com.adou.d17;

import java.io.FileWriter;
import java.io.IOException;
import java.util.Properties;

public class PropertiesTest2 {
    public static void main(String[] args) throws Exception {
        final Properties properties = new Properties();
        properties.setProperty("张无忌", "minmin");
        properties.setProperty("张翠山", "susu");
        properties.setProperty("殷素素", "cuishan");

        // 键值对数据存储到properties文件中
        properties.store(new FileWriter("d1-helloword-app\\src\\users2.properties"), " i save users");
    }
}
